package com.echo.yixiaowu.data.model.player

import android.os.Parcelable
import kotlinx.parcelize.Parcelize

@Parcelize
data class BaseHomeDetailData(
    val id: String,
    val type: CardContentType,
    val title: String,
    val content: String,
    val commentCount: Int,
    val likeCount: Int,
    val shareCount: Int,
    val favoriteCount: Int,
    val author: String,
    val avatar: String,
    val time: String
) : Parcelable

@Parcelize
sealed class CardDetailItemData : Parcelable {
    // 视频数据
    @Parcelize
    data class VideoItem(
        val videoUrl: String,
        val baseData: BaseHomeDetailData
    ) : CardDetailItemData()

    // 文本数据
    @Parcelize
    data class TextItem(
        val baseData: BaseHomeDetailData
    ) : CardDetailItemData()
}

data class CommentData(
    val id: String,
    val authorName: String,
    val content: String,
    val avatarResId: Int,
    var isLiked: Boolean = false,
    var likeCount: Int = 0,
    var isDisliked: Boolean = false,
    var isFavorites: Boolean = false
)